Optimal. Leaf size=99 \[ \frac{4 \left (a e^2-b d e+c d^2\right ) \tanh ^{-1}\left (\frac{b+2 c x}{\sqrt{b^2-4 a c}}\right )}{\left (b^2-4 a c\right )^{3/2}}-\frac{(d+e x) (-2 a e+x (2 c d-b e)+b d)}{\left (b^2-4 a c\right ) \left (a+b x+c x^2\right )} \]
[Out]
_______________________________________________________________________________________
Rubi [A] time = 0.153342, antiderivative size = 99, normalized size of antiderivative = 1., number of steps used = 3, number of rules used = 3, integrand size = 20, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.15 \[ \frac{4 \left (a e^2-b d e+c d^2\right ) \tanh ^{-1}\left (\frac{b+2 c x}{\sqrt{b^2-4 a c}}\right )}{\left (b^2-4 a c\right )^{3/2}}-\frac{(d+e x) (-2 a e+x (2 c d-b e)+b d)}{\left (b^2-4 a c\right ) \left (a+b x+c x^2\right )} \]
Antiderivative was successfully verified.
[In] Int[(d + e*x)^2/(a + b*x + c*x^2)^2,x]
[Out]
_______________________________________________________________________________________
Rubi in Sympy [A] time = 17.7727, size = 90, normalized size = 0.91 \[ \frac{\left (d + e x\right ) \left (2 a e - b d + x \left (b e - 2 c d\right )\right )}{\left (- 4 a c + b^{2}\right ) \left (a + b x + c x^{2}\right )} + \frac{4 \left (a e^{2} - b d e + c d^{2}\right ) \operatorname{atanh}{\left (\frac{b + 2 c x}{\sqrt{- 4 a c + b^{2}}} \right )}}{\left (- 4 a c + b^{2}\right )^{\frac{3}{2}}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In] rubi_integrate((e*x+d)**2/(c*x**2+b*x+a)**2,x)
[Out]
_______________________________________________________________________________________
Mathematica [A] time = 0.226355, size = 128, normalized size = 1.29 \[ \frac{a b e^2-2 a c e (2 d+e x)+b^2 e^2 x+b c d (d-2 e x)+2 c^2 d^2 x}{c \left (4 a c-b^2\right ) (a+x (b+c x))}+\frac{4 \left (e (a e-b d)+c d^2\right ) \tan ^{-1}\left (\frac{b+2 c x}{\sqrt{4 a c-b^2}}\right )}{\left (4 a c-b^2\right )^{3/2}} \]
Antiderivative was successfully verified.
[In] Integrate[(d + e*x)^2/(a + b*x + c*x^2)^2,x]
[Out]
_______________________________________________________________________________________
Maple [B] time = 0.01, size = 212, normalized size = 2.1 \[{\frac{1}{c{x}^{2}+bx+a} \left ( -{\frac{ \left ( 2\,ac{e}^{2}-{b}^{2}{e}^{2}+2\,bcde-2\,{c}^{2}{d}^{2} \right ) x}{c \left ( 4\,ac-{b}^{2} \right ) }}+{\frac{ab{e}^{2}-4\,acde+c{d}^{2}b}{c \left ( 4\,ac-{b}^{2} \right ) }} \right ) }+4\,{\frac{a{e}^{2}}{ \left ( 4\,ac-{b}^{2} \right ) ^{3/2}}\arctan \left ({\frac{2\,cx+b}{\sqrt{4\,ac-{b}^{2}}}} \right ) }-4\,{\frac{bde}{ \left ( 4\,ac-{b}^{2} \right ) ^{3/2}}\arctan \left ({\frac{2\,cx+b}{\sqrt{4\,ac-{b}^{2}}}} \right ) }+4\,{\frac{c{d}^{2}}{ \left ( 4\,ac-{b}^{2} \right ) ^{3/2}}\arctan \left ({\frac{2\,cx+b}{\sqrt{4\,ac-{b}^{2}}}} \right ) } \]
Verification of antiderivative is not currently implemented for this CAS.
[In] int((e*x+d)^2/(c*x^2+b*x+a)^2,x)
[Out]
_______________________________________________________________________________________
Maxima [F] time = 0., size = 0, normalized size = 0. \[ \text{Exception raised: ValueError} \]
Verification of antiderivative is not currently implemented for this CAS.
[In] integrate((e*x + d)^2/(c*x^2 + b*x + a)^2,x, algorithm="maxima")
[Out]
_______________________________________________________________________________________
Fricas [A] time = 0.217908, size = 1, normalized size = 0.01 \[ \left [-\frac{2 \,{\left (a c^{2} d^{2} - a b c d e + a^{2} c e^{2} +{\left (c^{3} d^{2} - b c^{2} d e + a c^{2} e^{2}\right )} x^{2} +{\left (b c^{2} d^{2} - b^{2} c d e + a b c e^{2}\right )} x\right )} \log \left (-\frac{b^{3} - 4 \, a b c + 2 \,{\left (b^{2} c - 4 \, a c^{2}\right )} x -{\left (2 \, c^{2} x^{2} + 2 \, b c x + b^{2} - 2 \, a c\right )} \sqrt{b^{2} - 4 \, a c}}{c x^{2} + b x + a}\right ) +{\left (b c d^{2} - 4 \, a c d e + a b e^{2} +{\left (2 \, c^{2} d^{2} - 2 \, b c d e +{\left (b^{2} - 2 \, a c\right )} e^{2}\right )} x\right )} \sqrt{b^{2} - 4 \, a c}}{{\left (a b^{2} c - 4 \, a^{2} c^{2} +{\left (b^{2} c^{2} - 4 \, a c^{3}\right )} x^{2} +{\left (b^{3} c - 4 \, a b c^{2}\right )} x\right )} \sqrt{b^{2} - 4 \, a c}}, -\frac{4 \,{\left (a c^{2} d^{2} - a b c d e + a^{2} c e^{2} +{\left (c^{3} d^{2} - b c^{2} d e + a c^{2} e^{2}\right )} x^{2} +{\left (b c^{2} d^{2} - b^{2} c d e + a b c e^{2}\right )} x\right )} \arctan \left (-\frac{\sqrt{-b^{2} + 4 \, a c}{\left (2 \, c x + b\right )}}{b^{2} - 4 \, a c}\right ) +{\left (b c d^{2} - 4 \, a c d e + a b e^{2} +{\left (2 \, c^{2} d^{2} - 2 \, b c d e +{\left (b^{2} - 2 \, a c\right )} e^{2}\right )} x\right )} \sqrt{-b^{2} + 4 \, a c}}{{\left (a b^{2} c - 4 \, a^{2} c^{2} +{\left (b^{2} c^{2} - 4 \, a c^{3}\right )} x^{2} +{\left (b^{3} c - 4 \, a b c^{2}\right )} x\right )} \sqrt{-b^{2} + 4 \, a c}}\right ] \]
Verification of antiderivative is not currently implemented for this CAS.
[In] integrate((e*x + d)^2/(c*x^2 + b*x + a)^2,x, algorithm="fricas")
[Out]
_______________________________________________________________________________________
Sympy [A] time = 6.49461, size = 517, normalized size = 5.22 \[ - 2 \sqrt{- \frac{1}{\left (4 a c - b^{2}\right )^{3}}} \left (a e^{2} - b d e + c d^{2}\right ) \log{\left (x + \frac{- 32 a^{2} c^{2} \sqrt{- \frac{1}{\left (4 a c - b^{2}\right )^{3}}} \left (a e^{2} - b d e + c d^{2}\right ) + 16 a b^{2} c \sqrt{- \frac{1}{\left (4 a c - b^{2}\right )^{3}}} \left (a e^{2} - b d e + c d^{2}\right ) + 2 a b e^{2} - 2 b^{4} \sqrt{- \frac{1}{\left (4 a c - b^{2}\right )^{3}}} \left (a e^{2} - b d e + c d^{2}\right ) - 2 b^{2} d e + 2 b c d^{2}}{4 a c e^{2} - 4 b c d e + 4 c^{2} d^{2}} \right )} + 2 \sqrt{- \frac{1}{\left (4 a c - b^{2}\right )^{3}}} \left (a e^{2} - b d e + c d^{2}\right ) \log{\left (x + \frac{32 a^{2} c^{2} \sqrt{- \frac{1}{\left (4 a c - b^{2}\right )^{3}}} \left (a e^{2} - b d e + c d^{2}\right ) - 16 a b^{2} c \sqrt{- \frac{1}{\left (4 a c - b^{2}\right )^{3}}} \left (a e^{2} - b d e + c d^{2}\right ) + 2 a b e^{2} + 2 b^{4} \sqrt{- \frac{1}{\left (4 a c - b^{2}\right )^{3}}} \left (a e^{2} - b d e + c d^{2}\right ) - 2 b^{2} d e + 2 b c d^{2}}{4 a c e^{2} - 4 b c d e + 4 c^{2} d^{2}} \right )} - \frac{- a b e^{2} + 4 a c d e - b c d^{2} + x \left (2 a c e^{2} - b^{2} e^{2} + 2 b c d e - 2 c^{2} d^{2}\right )}{4 a^{2} c^{2} - a b^{2} c + x^{2} \left (4 a c^{3} - b^{2} c^{2}\right ) + x \left (4 a b c^{2} - b^{3} c\right )} \]
Verification of antiderivative is not currently implemented for this CAS.
[In] integrate((e*x+d)**2/(c*x**2+b*x+a)**2,x)
[Out]
_______________________________________________________________________________________
GIAC/XCAS [A] time = 0.205645, size = 188, normalized size = 1.9 \[ -\frac{4 \,{\left (c d^{2} - b d e + a e^{2}\right )} \arctan \left (\frac{2 \, c x + b}{\sqrt{-b^{2} + 4 \, a c}}\right )}{{\left (b^{2} - 4 \, a c\right )} \sqrt{-b^{2} + 4 \, a c}} - \frac{2 \, c^{2} d^{2} x - 2 \, b c d x e + b c d^{2} + b^{2} x e^{2} - 2 \, a c x e^{2} - 4 \, a c d e + a b e^{2}}{{\left (b^{2} c - 4 \, a c^{2}\right )}{\left (c x^{2} + b x + a\right )}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In] integrate((e*x + d)^2/(c*x^2 + b*x + a)^2,x, algorithm="giac")
[Out]